
import request from '@/utils/request'

export function titQuery(data) {
  return request({
    url: `/md/commonBrowsers/selectPageItemGroup`,
    method: 'post',
    data: data
  })
}

export function save(data) {
  return request({
    url: `/md/itemGroups/save`,
    method: 'post',
    data: data
  })
}

export function search(data) {
  return request({
    url: `/md/itemGroups/query/?itemGroup=${data.num}`,
    method: 'get'
  })
}

export function searchItemGroup(data = '') {
  return request({
    url: `/md/itemGroups/itemGroupItemsByItem?item=${data}`,
    method: 'get'
  })
}

export function deleteItemGroup(data) {
  return request({
    url: `/md/itemGroups/delete`,
    method: 'get',
    params: data
  })
}

export function getPackingCustomData() {
  return request({
    url: `/md/commonCustomDatas/getPackingCustomData`,
    method: 'get'
  })
}

export function getItemGroupCustomData() {
  return request({
    url: `/md/commonCustomDatas/getItemGroupCustomData`,
    method: 'get'
  })
}
